#ifndef QSCRIPTEDITDIALOG_H
#define QSCRIPTEDITDIALOG_H

#include "../corelibglobal.h"

#include <QDialog>
#include <QMetaMethod>
#include <QStatusBar>

namespace SHAREDLIB
{
    class QAbstractProperty;
}

namespace CORELIB
{
    class QScriptEditView;
    class QWidgetView;
    class QFunctionView;
    class StyledBar;
    class QWidgetViewToolBar;
    class QFindWidget;
    class CORELIB_EXPORT QScriptEditDialog : public QDialog
    {
        Q_OBJECT
    public:
        explicit QScriptEditDialog(SHAREDLIB::QAbstractProperty* property,QWidget *parent = 0);

    signals:

    public slots:
        void    save();
        void    selectFunction(const QMetaMethod    &method);


    protected slots:
        void    script_find();
    protected:
        void    keyPressEvent(QKeyEvent *);

        void    closeEvent(QCloseEvent *);
    protected:
        QScriptEditView *m_editView;
        QWidgetView     *m_widgetView;
        QFunctionView   *m_functionView;
        StyledBar                                           *m_widgetStyledBar;
        QWidgetViewToolBar                                  *m_widgetToolBar;
        StyledBar                                           *m_functionStyledBar;
        QWidgetViewToolBar                                  *m_functionToolBar;
        StyledBar                                           *m_editStyledBar;
        SHAREDLIB::QAbstractProperty                        *m_property;
        QFindWidget                                         *m_find_widget;
    };

}

#endif // QSCRIPTEDITDIALOG_H
